import api from '@/http/api.js'
export default{
    namespaced:true,
    state:{
        rows:[],
        pages:0,
        total:0
     },
     mutations:{
            SET_SUB(state,payload){
                Object.assign(state,payload)
            }
     },
     actions:{
       async getTeacherAsync(context,payload){
            const {data}= await api.teacher.getTeachers(payload)
                    console.log(data);
            if(data.code){
                 context.commit('SET_SUB',data.data)
            }
         },
        }
}